package com.zhonghui.procurement.service.Impl;

import com.zhonghui.common.utils.DateUtils;
import com.zhonghui.procurement.domain.ProcurementPush;
import com.zhonghui.procurement.mapper.ProcurementPushMapper;
import com.zhonghui.procurement.service.IProcurementPushService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ProcurementPushServiceImpl implements IProcurementPushService {

    @Autowired
    private ProcurementPushMapper procurementPushMapper;

    /**
     * 查询采购-推送
     列表
     *
     * @param procurementPush 采购-推送

     * @return 采购-推送

     */
    @Override
    public List<ProcurementPush> selectProcurementPushList(ProcurementPush procurementPush)
    {
        return procurementPushMapper.selectProcurementPushList(procurementPush);
    }

    /**
     * 新增采购-推送

     *
     * @param procurementPush 采购-推送

     * @return 结果
     */
    @Override
    public int insertProcurementPush(ProcurementPush procurementPush)
    {
        procurementPush.setCreateTime(DateUtils.getNowDate());
        return procurementPushMapper.insertProcurementPush(procurementPush);
    }
}
